package cc.aiee.wxpay.config;

import java.io.Serializable;

import javax.validation.constraints.NotBlank;

import cc.aiee.core.bean.PayBaseConfig;
import cc.aiee.core.interfaces.PayJsonBeanInterface;
import cc.aiee.core.kit.KitJson;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@AllArgsConstructor
@NoArgsConstructor
public class WxPayScoreConfig extends PayBaseConfig implements Serializable, PayJsonBeanInterface {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@NotBlank
	private String appId;
	
	// 商户私钥
	@NotBlank
	private String privateKey;

	// 商户号
	@NotBlank
	private String mchId;

	// 商户秘钥
	@NotBlank
	private String apiSecret;
	
	// 商户证书序列号
	@NotBlank
	private String mchSerialNo;

	// V3秘钥
	@NotBlank
	private String apiV3Key;

	@NotBlank
	private String notifyUrl;

	@NotBlank
	private String serviceId;

	@Override
	public String toJson() {
		return KitJson.toJSONString(this);
	}

	@Override
	public String toJson(boolean prettyFormat, boolean ignoreNull) {
		return KitJson.toJSONString(this, prettyFormat, ignoreNull);
	}

}
